The present disclosure relates to the field of data processing, and more specifically to converting over-range colors.
Digital devices that create (e.g., scanners and digital cameras), display (e.g. CRT and LCD monitors), or print (e.g. ink jet and laser printers) colors typically define color data using color spaces. Generally, a color space is a combination of a color model and a gamut. A color model defines each color within the model using components, such as, in the case of a Red, Green, Blue (RGB) color model, the levels of red, green, and blue light components needed to create each color. Levels of each component in the RGB color model typically range from 0 to 100 percent of full intensity, or which may be represented on a scale of 0 to 1. By varying the levels or intensities of the components, each color in the color model may be created. However, as a practical matter a device is often limited in its ability to create pure red, green, or blue light, which limits its range of colors or color gamut. A gamut is simply the range of colors that may be displayed on or captured by a particular device.
The differences in device gamuts lead to differences in color spaces between two devices. For example, two devices that use RGB may show different colors when each displays its most intense red. The most intense red on a first device may have an intensity of 1 for the R component and 0 for the G and B components. However, the color that looks the same as the most intense red of the first device may have a red intensity of 0.85 on a second device. Moreover, the G and B component intensities may even be 0.05 on the second device. In other words, the same perceived “red” color has different RGB component values depending on the device, on the first device it may be (1, 0, 0) and on the second device that same “red” may be (0.85, 0.05, 0.05). This means that an image file containing only RGB values, if displayed directly by both devices, would appear differently on the two devices.
To solve this problem of the same component values appearing differently on different devices, color spaces are defined in relation to device-independent color spaces, which define colors in more absolute terms. Some examples of device-independent color spaces include the CIE XYZ and CIE L*a*b* color spaces. Many systems and applications use the sRGB color space, whose relation to the device-independent color spaces is well-known in the art. The relationship of a device's native color space with a device-independent color space typically is described by some combination of formulas, transfer functions, matrices, and look up tables. This relationship may be stored in an International Color Consortium (ICC) profile for the device. The device-independent color space may be used as an intermediate when converting from one device-dependent color space to another.
The conversion from one color space to another may be done through a series of processing steps. Some processing steps may be more computationally intensive than others. Some processing steps may require interpolation. Generally, there is a tradeoff between the number of steps, the complexity of each step, speed, and accuracy. In some applications, speed is of the essence and accuracy is sacrificed by reducing the number of steps and/or the complexity of the individual steps. Other applications may require exacting conversion, in which case conversion speed may decrease. Often to increase speed, a three-dimensional look up table (3D LUT) is used either alone or with another simple processing step. A 3D LUT maps points in one color space to corresponding points in another color space. For example, a color in a first RGB color space may have the color component values of (0, 0.4572, 0.82) which, when converted to a second RGB color space, the color may have the color component values (0.001, 0.5013, 0.764). A 3D LUT may be constructed by transforming a regularly spaced grid of colors in a first color space to a second color space using the most accurate processing steps. Each grid point and its corresponding transform point in the second color space may be stored in the 3D LUT. Converting colors that do not correspond to the grid points would involve interpolation, therefore, the more grid points the more accurate the conversion. However, increasing the number of the grid points complicates the 3D LUT and may result in an increase in processing time.